import sizeConst from "../constant/size.const"
import categoryEnum from "../enum/category.enum"
import sizeEnum from "../enum/size.enum"
import Command from "./command"
export class CaptureSnapshotCommand extends Command {
  constructor(e: { maxSize: string; aspect: number; category: string; onProgress: any; waitForUpload?: any }) {
    super()
    this.id = "CAPTURE_SNAPSHOT"
    this.payload = {
      maxSize: e.maxSize || sizeEnum.ULTRAHIGH,
      aspect: e.aspect || sizeConst.aspect,
      category: e.category || categoryEnum.USER,
      onProgress: e.onProgress,
      waitForUpload: e.waitForUpload
    }
  }
}
export class EquirectSnapshotCommand extends Command {
  constructor(e: { onProgress: any; waitForUpload?: any }) {
    super()
    this.id = "EQUIRECTANGULAR_SNAPSHOT"
    this.payload = {
      onProgress: e.onProgress,
      waitForUpload: e.waitForUpload
    }
  }
}
export class RenameSnapshotCommand extends Command {
  constructor(id: any, name: any) {
    super()
    this.id = "RENAME_SNAPSHOT"
    this.payload = { id, name }
  }
}
export class DeleteSnapshotCommand extends Command {
  constructor(id: any) {
    super()
    this.id = "DELETE_SNAPSHOT"
    this.payload = { id }
  }
}
export class UploadSnapshotCommand extends Command {
  constructor(snapshot: any) {
    super()
    this.id = "UPLOAD_SNAPSHOT"
    this.payload = { snapshot }
  }
}
